import data from 'dayjs'
import utc from 'dayjs/plugin/utc'
const DATA_TIME_FORMAT = 'YYYY-MM-DD HH:mm:ss'
data.extend(utc)

export default function formatUtcString(
  UtcString: string,
  format: string = DATA_TIME_FORMAT
) {
  return data.utc(UtcString).utcOffset(8).format(format)
}
